package org.flexspeedup.blog.controllers
{
import mx.rpc.remoting.RemoteObject;

import org.flexspeedup.blog.models.IStaticPage;

/**
 * Defines the interface to control static pages content
 */
public interface IStaticPageController
{    

    //--------------------------------------------------------------------------
    //
    //  Properties
    //
    //--------------------------------------------------------------------------

    //--------------------------------
    // staticPageModel
    //--------------------------------
    [Bindable(event="propertyChange")]
    /**
     * The static page model
     */
    function get staticPageModel():IStaticPage;
    function set staticPageModel(value:IStaticPage):void;

    //--------------------------------
    // blogService
    //--------------------------------
    /**
     * The blog remote object
     */
    function get blogService():RemoteObject;
    function set blogService(value:RemoteObject):void;
    
    //--------------------------------------------------------------------------
    //
    //  Methods
    //
    //--------------------------------------------------------------------------

    //----------------------------------
    //  saveStaticPage
    //----------------------------------
    /**
     * Creates / updates a static page in the datastore
     */
    function saveStaticPage(page:IStaticPage):void;

    //----------------------------------
    //  getStaticPage
    //----------------------------------
    /**
     * fetches a static page from the datastore
     */
    function getStaticPage(pageName:String):void;

    //----------------------------------
    //  deleteStaticPage
    //----------------------------------
    /**
     * deletes a static page from the datastore
     */
    function deleteStaticPage(pageName:String):void;
    
}
}